<?php
/**
 * Created by PhpStorm.
 * User: chengxun
 * Date: 2017/7/12
 * Time: 14:55
 */

namespace app\common\model;



use think\Model;
class DomainConfig extends Model
{
    public function get_data($where=[],$page=[]){
        $data = $this
            ->alias('a')
            ->field('a.*')
            ->where($where)
            ->order('a.status desc, a.id desc')
            ->paginate(13,false,$page);
        return $data;
    }
    public function get_host_module($host){
        $data = $this->where(['host'=>$host,'status'=>1])->find();
        return $data;
    }
}